package com.csxh.web.spring.hangler;

import java.io.IOException;

import javax.servlet.ServletConfig;
import javax.servlet.ServletException;
import javax.servlet.ServletRequest;
import javax.servlet.ServletResponse;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.web.servlet.support.RequestContextUtils;

public class TestServletHandler extends HttpServlet {

	
	/**
	 * 
	 */
	private static final long serialVersionUID = 2483177175988865219L;

	public void init(ServletConfig arg0) throws ServletException {
		// TODO Auto-generated method stub

	}

	@Override
	protected void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
		System.out.println("we go here");
	    
		req.setAttribute("data", "ok");
		
		req.getRequestDispatcher("/result.jsp").forward(req, resp);
		
	}

}
